home *** CD-ROM | disk | FTP | other *** search
- /*
- *--- PListMom.cpp --------------------------------------------------------
- * Copyright (c) 1995-96 Adobe Systems Incorporated. All rights reserved.
- * Created on Thu, Oct 12, 1995 @ 10:00 PM by Paul Ferguson.
- *
- * Description: For notes about this class, refer to the
- * PCL documentation file PListMom.html
- *-------------------------------------------------------------------------
- */
-
- #include "PListMom.h"
-
- PListMom::PListMom()
- : numItems(0), itemsPtr(0), curItem(0), curItemPtr(0)
- {
-
- }
-
- PListMom& PListMom::operator=(const char * buf)
- {
- itemsPtr = buf;
- numItems = *(short *) itemsPtr;
- itemsPtr += 2;
-
- curItem = 0;
- curItemPtr = itemsPtr;
-
- return *this;
- }
-
- void PListMom::Update(const char * ch)
- {
- if (++curItem >= numItems)
- {
- Reset();
- }
- else
- {
- curItemPtr = ch;
- }
- }
-
- void PListMom::Reset()
- {
- curItem = 0;
- curItemPtr = itemsPtr;
- }
-
- // end of PListMom.cpp
-